package com.rico.gallery.service;

import com.rico.gallery.socket.SocketConnection;

public class User {

    private UserInfo userInfo;

    private String sessionId;

    private SocketConnection socketConnection;

    private boolean isLogin=false;

    private long createTime;

    public User(){}

    public User(SocketConnection socketConnection) {
        this.socketConnection = socketConnection;
        this.createTime=System.currentTimeMillis();
    }

    public UserInfo getUserInfo() {
        return userInfo;
    }

    public void setUserInfo(UserInfo userInfo) {
        this.userInfo = userInfo;
    }

    public String getSessionId() {
        return sessionId;
    }

    public void setSessionId(String sessionId) {
        this.sessionId = sessionId;
    }

    public SocketConnection getSocketConnection() {
        return socketConnection;
    }

    public void setSocketConnection(SocketConnection socketConnection) {
        this.socketConnection = socketConnection;
    }

    public boolean isLogin() {
        return isLogin;
    }

    public void setLogin(boolean login) {
        isLogin = login;
    }

    public long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(long createTime) {
        this.createTime = createTime;
    }
}
